package com.pencilisland.pay.mgt.app.service;

import org.apache.poi.ss.usermodel.Workbook;
import org.springframework.data.domain.Page;
import org.springframework.web.multipart.MultipartFile;

import com.pencilisland.pay.mgt.app.entity.OrderInfoEntity;

/**
 * 订单服务
 * 
 * @author Breeze
 *
 */
public interface OrderService {

	/**
	 * 分页查询订单列表
	 * 
	 * @param cretiria
	 * @param start
	 * @param length
	 * @return
	 */
	Page<OrderInfoEntity> orderList(OrderInfoEntity cretiria, int start, int length);

	/**
	 * 加载订单数据
	 * 
	 * @param id
	 * @return
	 */
	OrderInfoEntity loadData(String orderNo);

	/**
	 * 撤销关闭订单
	 * 
	 * @param orderNos
	 */
	void cancel(String orderNos,String remark);

	/**
	 * 订单发货处理
	 * @param orderNos
	 * @param trackingNumber
	 * @param remark
	 */
	void send(String orderNos, String trackingNumber, String remark);

	/**
	 * 组装生成excel
	 * @param workbook
	 * @param cretiria
	 */
	void buildKuaidi100Excel(Workbook workbook, OrderInfoEntity cretiria);

	/**
	 * 组装中通excel
	 * @param workbook
	 * @param cretiria
	 */
	void buildZhongtongExcel(Workbook workbook, OrderInfoEntity cretiria);

	/**
	 * 导入中通返回数据
	 * @param file
	 * @throws Exception 
	 */
	void importZhongtong(MultipartFile file) throws Exception;

}
